package com.usefullc.user.dao;

import com.usefullc.user.domain.AuthRes;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.transaction.annotation.Transactional;

/**
 * @author: Sampson
 * @date: 2022-01-10 14:07
 */
public interface AuthResDao extends JpaRepository<AuthRes, Long> {

    @Transactional
    @Modifying
    @Query(value = "delete from `u_auth_res` t  where t.code like ?1% ",nativeQuery = true)
    int delByCodeLike(String codeLike);


}
